Class("UIImage",
{
	// --------- inheritance
	isa: UISimpleControl,

	// --------- constructor
	after:
	{
		initProperties: function(id, props)
		{
			// custom binders
			var srcGet = function()
			{
				return this.getImage().src;
			};

			var srcSet = function(src)
			{
				var img = new Image();
				img.src = src;
				this.setImage(img);
			};

			// additional props
			this.addProperty("Source",			srcGet,					srcSet, "../Resources/Images/Default/UIImage.png");
			this.addProperty("CropRegion",		this.node.getCrop,		this.node.setCrop);

			// refine old props
			this.SetProperty("Size", {width: 480, height: 320});
		}
	},

	// --------- methods
	override:
	{
		initNode: function()
		{
			return new Kinetic.Image();
		}
	}
})